package campus.aiit.ssl.util;

public class DateFormat {

    public String format(String time){
        try {
            if (time.equals("")){
                return null;
            }
        }catch (NullPointerException e){
            return null;
        }
        String[] timeArr= time.split("-");
        return timeArr[0]+"-"+String.format("%02d",Integer.parseInt(timeArr[1]))+"-"+String.format("%02d",Integer.parseInt(timeArr[2]));
    }
}
